% TEST_ID: LANG-EXPAND-0118
% CATEGORY: language/string
% 测试 string 的比较判断

function test_string_startsWith()
x = 'hello';
y = 'he';
z = startsWith(x, y);
assert(z);

x = {'hello', 'world'};
y = {'he', 'wo'};
z = startsWith(x, y);
assert(z(1));
assert(z(2));

x = {'Hello', 'world', 'abche'};
y = {'he', 'wO'};
z = startsWith(x, y, 'ignoreCase', true);
assert(z(1));
assert(z(2));
assert(~z(3));


assert(startsWith("abc", "a", "IgnoreCase", true));
assert(endsWith("abc", "c", "IgnoreCase", true));